package string;

public class SubStringDemo {
    public static void main(String[] args) {
        String str = "ww.tedu.cn";
        String sub = str.substring(1, 4);//1到3不含4
        System.out.println(sub);
//从下标5开始一直到字符串末尾
        System.out.println(str.substring(5));
    }
}
